package com.czk.service;

import com.czk.pojo.Car;

/**
 * @Author:ChenZhangKun
 * @Date: 2021/9/17 14:21
 */
public class CarServiceImpl implements CarService {
    @Override
    public Car getCarInfo(String carBrand) {
        Car car = new Car();
        if (carBrand.equals("audi")) {
            car.setBrand("audi");
            car.setOwner("Tom");
            car.setPlateNum("皖A11011");
            car.setPrice(50.00);
        } else if (carBrand.equals("bmw")) {
            car.setBrand("bmw");
            car.setOwner("Jack");
            car.setPlateNum("皖A8888M");
            car.setPrice(60.00);
        } else {
            car.setBrand("其他");
            car.setOwner("Rose");
            car.setPlateNum("未知");
            car.setPrice(00.00);
        }
        return car;
    }
}
